<script>
$(document).ready(function(){
	$("#parent_id option[value='<?php echo $this->parentId?>']").attr('disabled','disabled');
//	$(".msg_body").hide();
    $(".msg_head").click(function(){
    	 $("#ui-icon").toggleClass('ui-icon-circle-triangle-e').toggleClass('ui-icon-circle-triangle-s');
        $(".msg_body").slideToggle(250);
    });
    $.get('<?php echo $this->route("getaclaccess")?>',{id:'<?php echo $this->id?>'}, function(data){
        $("#permList").html(data);
       });
});
</script>
<style>
.msg_head {margin-top:5px;}
.msg_body {
    padding: 5px 10px 15px;
    background-color:#F4F4F8;
}
.allow {background-color: #05d;color:#fff;padding:0 2px}
.deny {background-color: #d50;color:#fff;padding:0 2px}
</style>
<form id="setAccess" action="<?php echo $this->route('edit')?>" method="post">
<?php echo $this->form->title?>
<div>
<?php echo $this->form->parent_id?>
<?php echo $this->form->id_kind?>

<dt> </dt>
<dd  id="temp_div" style="display: none">
<select id="temp_id" name="item_id"></select>
<?php echo $this->form->allow?>
</dd>
</div>
<?php if ($this->controllerData):?>
<div class="msg_head">
<a href="#" class="fg-button fg-button-icon-left ui-state-default ui-corner-all">
<span id="ui-icon" class="ui-icon ui-icon-circle-triangle-e"></span><?php echo $this->translate('Detail authorization')?></a>
</div>
<div style="clear:both"></div>
<div class="msg_body">
<?php echo $this->render('manager/getitems.phtml')?>
</div>
<?php endif?>
<?php echo $this->form->save?>
<?php echo $this->form->resource_id?>
<?php echo $this->form->id?>
</form>

<div id="permList">
</div>